package com.proj.mapper;

import com.proj.pojo.User;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.web.bind.annotation.Mapping;

import java.util.List;

/**
 * user mapper
 */
@Mapper
public interface UserMapper {

    /**
     * 查询用户列表
     * @return
     */
    public List<User> getUserList();

    /**
     * 添加用户
     * @param user
     * @return
     */
    @Insert("insert into user(username,usercode,userpassword) values(#{userName},#{userCode},#{userPwd})")
    public int addUser(User user);
}
